package elcom.run;

import elcom.control.inputter.Inputter;
import elcom.control.outputter.Outputter;
import elcom.control.processor.ProcessorMain;
import elcom.model.data.QueueIO;
import elcom.model.data.Student;

public class MainThread extends Thread {
	public static QueueIO<Student> queIn = new QueueIO<>();
	private static QueueIO<String> queOut = new QueueIO<>();

	@Override
	public void run() {
		Thread inputter = new Inputter(queIn);
		inputter.setName("Inputter");
		inputter.start();

		Thread processor = new ProcessorMain(queIn, queOut);
		processor.setName("ProcessorMain");
		processor.start();

		Thread outputter = new Outputter(queOut);
		outputter.setName("Outputter");
		outputter.start();
		super.run();
	}
}
